package com.liliya.service.impl;

import com.liliya.dao.CateDao;
import com.liliya.dao.impl.CateDaoImpl;
import com.liliya.pojo.Cate;
import com.liliya.service.CateService;

import java.util.List;

/**
 * @Description TODO
 * @Author hhy
 * @Date 2021/1/9 17:49
 */
public class CateServiceImpl implements CateService {
    private CateDao cateDao = new CateDaoImpl();

    @Override
    public void insertCate(Cate cate) {
        cateDao.insertCate(cate);
    }

    @Override
    public void deleteCate(Integer cateNum) {
        cateDao.deleteCate(cateNum);
    }

    @Override
    public void updateCate(Cate cate) {
        cateDao.updateCate(cate);
    }

    @Override
    public Cate findCateByNum(Integer cateNum) {
        return cateDao.findCateByNum(cateNum);
    }

    @Override
    public Cate findCateByRow(Integer rowNum) {
        return cateDao.findCateByRow(rowNum);
    }

    @Override
    public int totalCate() {
        return cateDao.totalCate();
    }

    @Override
    public List<Cate> findCate(Integer start, Integer end) {
        return cateDao.findCate(start,end);
    }
}
